package com.xwp.aprt.controller;

import com.xwp.aprt.dao.Room;
import com.xwp.aprt.dao.RoomExample;
import com.xwp.aprt.mapper.RoomMapper;
import com.xwp.aprt.result.Result;
import com.xwp.aprt.service.RoomService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * Description
 * User: ORANGE
 * Date: 2022/8/1
 * Time: 21:43
 */
@RestController
@RequestMapping("/admin/aprt/aprtSet")
@Slf4j
@Api(tags = "公寓设置接口")
public class apartmentSetController {
    @Autowired(required = false)
    private RoomMapper roomMapper;
    @Autowired(required = false)
    private RoomExample roomExample;

    @ApiOperation(value = "查看公寓列表")
    @GetMapping("findAll")
    @Transactional(readOnly = true)
    public Result findAll(){
        Room room = roomMapper.selectByPrimaryKey(20220001);

        return Result.ok(room);
    }


}
